aboutsummaryrefslogtreecommitdiffstats
path: root/src/routes/(app)/[username]
diff options
context:
space:
mode:
authorAdam Soltys <[email protected]>2023-03-11 17:47:15 -0800
committerAdam Soltys <[email protected]>2023-03-11 17:47:15 -0800
commitf5eaf3eac19e0e2902b894effb14b58cc8c21d2d (patch)
treef9a16fcf187ab1657bcc3d97fd5b2df4e35f95e6 /src/routes/(app)/[username]
parentffb2a1c2ccfeb8d6002644e2fcefe60a7fd20d05 (diff)
downloadcoinos-ui-f5eaf3eac19e0e2902b894effb14b58cc8c21d2d.tar.gz
coinos-ui-f5eaf3eac19e0e2902b894effb14b58cc8c21d2d.zip
fix param name
Diffstat (limited to 'src/routes/(app)/[username]')
-rw-r--r--src/routes/(app)/[username]/invoice/+server.js6
-rw-r--r--src/routes/(app)/[username]/invoice/[hash]/tip/+page.svelte4
2 files changed, 8 insertions, 2 deletions
diff --git a/src/routes/(app)/[username]/invoice/+server.js b/src/routes/(app)/[username]/invoice/+server.js
index 1321739e..461d380c 100644
--- a/src/routes/(app)/[username]/invoice/+server.js
+++ b/src/routes/(app)/[username]/invoice/+server.js
@@ -1,5 +1,7 @@
import { auth, post } from '$lib/utils';
import { json } from '@sveltejs/kit';
-export let POST = async ({ cookies: c, request: r }) =>
- json(await post('/invoice', await r.json(), auth(c)));
+export let POST = async ({ cookies: c, request: r }) => {
+ let j = await r.json();
+ return json(await post('/invoice', j, auth(c)));
+};
diff --git a/src/routes/(app)/[username]/invoice/[hash]/tip/+page.svelte b/src/routes/(app)/[username]/invoice/[hash]/tip/+page.svelte
index 296ef9c6..9d9021a6 100644
--- a/src/routes/(app)/[username]/invoice/[hash]/tip/+page.svelte
+++ b/src/routes/(app)/[username]/invoice/[hash]/tip/+page.svelte
@@ -59,6 +59,7 @@
let { invoice, id, user } = data;
let {
amount,
+ hash,
type,
rate,
received,
@@ -79,6 +80,7 @@
({ invoice, id } = data);
({
amount,
+ hash,
type,
rate,
received,
@@ -110,6 +112,8 @@
<input type="hidden" name="rate" value={rate} />
<input type="hidden" name="prompt" value="false" />
<input type="hidden" name="type" value={type} />
+ <input type="hidden" name="hash" value={hash} />
+
<input type="hidden" name="request_id" value={invoice.request?.id} />
<h1 class="text-4xl font-semibold my-8">{$t('invoice.addTipq')}</h1>